﻿@model FCTC_Web.Models.VehicleEstimation
@{
    ViewBag.Title = "Edit";
}
<h2>
    编辑</h2>
@*<link href="@Url.Content("~/Content/jquery-ui-1.8.16.custom.css")" rel="stylesheet" type="text/css" />
<script src="@Url.Content("~/Scripts/jquery-1.5.1.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery-ui-1.8.16.custom.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery-ui-timepicker-addon.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.ui.datepicker-zh-CN.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>*@
    @Combres.HtmlExtensions.CombresLink("backjs")
<script type="text/javascript">
    $(document).ready(function () {
        $('#AppointmentDate').datetimepicker(
                { hourMin: 9,
                    hourMax: 16,
                    showOn: 'both',
                    buttonImage: '/images/calendar.png',
                    buttonImageOnly: true
                });
    });
</script>
<style>
td image{ margin-left:5px; height:24px; width:50px; cursor:hand;}
</style>
@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>评估预约信息</legend>

        <table width="90%" style="background-color:#f6fdfd; margin-top:20px;"  align="center">
            <tr>
                <td style="width:150px; text-align:right;">
                    <span class="headtitle">@Html.LabelFor(model => model.AppointmentDate)：</span>
                </td>
                <td>
                    <span class="ie6">@Html.TextBoxFor(i => i.AppointmentDate, new { id = "AppointmentDate", @name = "AppointmentDate" })
                @Html.ValidationMessageFor(model => model.AppointmentDate)</span> 
                </td>
                <td style="width:150px; text-align:right;">
                    <span class="headtitle">@Html.LabelFor(model => model.EstimatorID, "评估师")：</span>
                </td>
                <td>
                    <span class="headtitles">@Html.DropDownList("EstimatorID", "--请选择--")
                                     @Html.ValidationMessageFor(model => model.EstimatorID)</span> 
                </td>
            </tr>
            <tr>
                <td style="width:150px; text-align:right;">
                    <span class="headtitle">@Html.LabelFor(model => model.AppointmentStatus)：</span>
                </td>
                <td>
                    <span class="headtitles">@Html.DropDownListFor(model => model.AppointmentStatus, new SelectList(new List<string>{  
                      "未处理", 
                       "正在处理", 
                       "客户放弃评估",
                       "评估完成"}), "--请选择--")
            @Html.ValidationMessageFor(model => model.AppointmentStatus)</span> 
                </td>
                <td style="width:150px; text-align:right;">
                    <span class="headtitle">@Html.LabelFor(model => model.ApplyerMsg)：</span>
                </td>
                <td>
                    <span class="txt">@Html.TextAreaFor(model => model.ApplyerMsg)
                    @Html.ValidationMessageFor(model => model.ApplyerMsg)</span> 
                </td>
            </tr>
             <tr>
                <td style="width:150px; text-align:right;">
                    <span class="headtitle">@Html.LabelFor(model => model.Title)：</span>
                </td>
                <td>
                    <span class="ie6">@Html.EditorFor(model => model.Title)
                    @Html.ValidationMessageFor(model => model.Title)</span> 
                </td>
                <td style="width:150px; text-align:right;">
                    <span class="headtitle">@Html.LabelFor(model => model.Description)：</span>
                </td>
                <td>
                    <span class="txt">@Html.TextAreaFor(model => model.Description)
                    @Html.ValidationMessageFor(model => model.Description)</span> 
                </td>
                @Html.HiddenFor(model => model.ID)
                @Html.Hidden("VehicleID", Model.Vehicle.ID)
                @Html.Hidden("PersonalID", Model.Personal.ID)
            </tr>
        </table>
           
    </fieldset>
    <fieldset>
        <legend>预约人信息</legend>
        <div class="editor-field">
            @Html.Partial(@"~\views\shared\controls\PersonalViewEdit.cshtml", Model.Personal)
        </div>
    </fieldset>
    @Html.ActionLink("进入车辆细节信息编辑", "Edit", "Vehicle", new { id = Model.VehicleID }, null)
     
    <p>
        <input type="submit" value="保存" />
    </p>
}
<div>
    @Html.ActionLink("返回列表", "Index")
</div>
